A. Field of the Invention
This invention relates in general to a software system for memory devices and, in particular, to an optimized access software system for accessing memory devices requiring block writing.
B. Description of the Related Art
Information storage in computer systems involves the use of memory devices of various types. In general, information in relation to the operation of a computer system includes data and code stored in computer memory in the form of computer files, which are put away in the non-volatile memory of the computer either temporarily or permanently. This memory subsystem of a computer for file storage is sometimes referred to as the secondary memory.
On the other hand, there are also information directly related to the on-going computing activities of a computer that also include both code and data stored in the main system memory, sometimes referred to as scratch pad memory. Working program codes and some of the data for a computing task are retrieved from the secondary memory in the form of files. Data for the task is then worked on and may be stored back to the secondary memory temporarily during the task or permanently when the task concludes.
In a typical microprocessor-based personal computer system, high-speed semiconductor memory devices including SRAM (Static Random Access Memory) and DRAM (Dynamic Random Access Memory) are used as the main, or primary, memory. For computer files, large-capacity yet relatively slower hard disk drives are normally used. There are of course the use of non-volatile EEPROM (electrically erasable-programmable read-only memory) devices known as Flash memory for the storage of certain code and data in the mass-production PC, but the content in this memory is seldom changed. For example, BIOS (Basic Input/Output System) codes stored in Flash memory are only changed when upgraded.
By contrast, for many other mass-production and cost-sensitive computer systems such as multimedia/entertainment set-top boxes, Internet appliances (IA) of various kinds and communication equipments etc., the use of information storage devices is somewhat more mixed. Depending on design, a computer system may employ Flash memory for the storage of permanent computer files instead of HDD (Hard Disk Drive) while another may usc sections of its Flash memory as scratch pad memory.
Regardless of what information goes into what memory device in a computer system, a management software system is brought up on line once the computer boots up to manage all these information access activities, including the storage and retrieval of information into and out of these memory devices. In a general-purpose computer system such as a PC, main-stream operating systems of various flavor can be used, and in a dedicated computer device such as a network router or switch, either a minimum Linux from the public domain or some proprietary operating system is applicable.
Flash memory devices are becoming more used in computer systems for various storage requirements mentioned above. They can be used as emulated disk drives to replace HDD in harsh operating environments such as industrial and military. They can also be used in commercial applications including the storage of images taken by digital camera or the holding of personal information in devices such as USB (Universal Serial Bus) thumb-drives. Many dedicated-application embedded systems also use all-Flash emulated disk subsystems similar as in industrial and military since the total amount of Flash memory space required is relatively small in these applications. With a small Flash-based file storage subsystem in these embedded systems, the cost isn't necessarily higher, and other factors including reliability and compactness further justify the costs.
No matter what application a Flash memory device is used, it is subject to at least two limitations. First, cost factors have led to the requirement that write accesses in a Flash memory device be performed in blocks, not single memory locations. In other words, a typical mass-production Flash memory writes data into its memory cells in blocks of continuous memory locations even if only the writing of one address is intended. Without a housekeeping operation such as defragmenting reorganization of the entire memory content, holes of memory spaces rendered useless are left in the memory device. The direct result of this block-use is much reduced utilization efficiency of the entire memory space.
Second, memory cells in a Flash device have life cycle limitation of a few hundred write accesses. Conventional block writing schemes typically employed by computer systems installed with Flash memories tend to access some memory cells repeatedly while leaving others for rare access. This leads to a service life shorter than expected.